﻿#region Using Section
using ImageRio = Rio.Framework.WCFService.RioWcfServices.ImageRio;

#endregion

namespace Rio.Framework.Pages.Events
{
    /// <summary>
    /// Delegate definition
    /// </summary>
    /// <param name="sender"></param>
    /// <param name="args"></param>
    public delegate void DirectorySelectedHandler(object sender, DirectorySelectedEventArgs args);

    /// <summary>
    /// Events arguments used by DirectorySelectedHandler
    /// </summary>
    public class DirectorySelectedEventArgs : DocumentSelectedEventArgs
    {
        public enum Mode
        {
            OpenDirectory = 0,
            ReturnDIrectory = 1
        }

        /// <summary>
        /// Used to get the current directory name that must be displayed
        /// </summary>
        public string DirectoryName { get; internal set; }
        /// <summary>
        /// Name of the current directory
        /// </summary>
        public ImageRio SelectedDirectory { get; internal set; }
        /// <summary>
        /// 
        /// </summary>
        public Mode DirectoryMode { get; set; }


        public DirectorySelectedEventArgs()
            : this(string.Empty)
        {
        }

        public DirectorySelectedEventArgs(Mode DirectoryMode)
            :this(string.Empty)
        {
            this.DirectoryMode = DirectoryMode;
        }

        public DirectorySelectedEventArgs(string DirectoryName)
            :this(DirectoryName, null)
        {
        }
        public DirectorySelectedEventArgs(string DirectoryName, ImageRio SelectedDirectory)
        {
            this.DirectoryName = DirectoryName;
            this.SelectedDirectory = SelectedDirectory;
        }

    }
}
